#ifndef THIRDFLOOR_H
#define THIRDFLOOR_H

#include <QMainWindow>
#include <QApplication>
#include <QTime>

namespace Ui {
class ThirdFloor;
}

class ThirdFloor : public QMainWindow
{
    Q_OBJECT

public:
    explicit ThirdFloor(QWidget *parent = 0);
    ~ThirdFloor();
    void paintEvent(QPaintEvent *event);
    void Init();
    void keyPressEvent(QKeyEvent *event);
    void Sleep(unsigned int msec);

private slots:
    void Enemy_update();

signals:
    void Oversignal();
    void Successsignal();

private:
    Ui::ThirdFloor *ui;
    QTimer *timer;
    QRect Person;
    QPixmap BlueDoor;
    QPixmap RedDoor;
    QRect Wall[19];
    QRect Enemy[19];
    QRect Secrect[5];
    int s[5];
    int nDirection[19];
    QString sDisplay;
    bool blsRun;
    bool blsOver;
    bool blsSuccess;
    int ran_num;

};

#endif // FIRSTFLOOR_H
